Re: Transaction Status Python Tests
Thanks everyone for working it out. On Tue, Aug 20, 2019, 6:54 AM Akshay Joshi wrote: > Thanks Khushboo, patch applied. > > It works, I have tested for multiple database servers. > > On Tue, Aug 20, 2019 at 10:03 AM Khushboo Vashi < > khushboo.va...@enterprisedb.com> wrote: > >> Hi, >> >> Please find the attached patch to fix the test cases. >> >> Thanks, >> Khushboo >> >> On Tue, Aug 20, 2019 at 9:52 AM Akshay Joshi < >> akshay.jo...@enterprisedb.com> wrote: >> >>> Hi Yosry >>> >>> Not able to figure out the cause today as well, I have comment out the >>> disable auto commit test cases for Transaction Status. Please look into it >>> once you will have some time. >>> >>> On Mon, Aug 19, 2019 at 6:05 PM Yosry Muhammad >>> wrote: >>> This behaviour is very strange. Maybe another test running in parallel is enabling auto-commit or commiting the transaction? There is a problem with my machine right now, can you skip this test for this release if the issue is not resolved? Sorry for the inconvenience. On Mon, Aug 19, 2019, 2:30 PM Akshay Joshi < akshay.jo...@enterprisedb.com> wrote: > Hi Yosry > > Test cases with auto commit disabled gets failed for following > scenario only: > >- Run all test cases on more than one server "*--pkg all* *--exclude >feature_tests"*. For first sever all the tests passed and for >second onwards fail for all. >- If you run only sqleditor test cases on multiple server then no >issues. Strange behaviour. >- We have tried manually on pgAdmin4 and seems the test cases >should pass logic seems correct to me. > > def runTest(self): > self._create_test_table() > self._set_auto_commit(self.is_auto_commit_enabled) > self._execute_select_sql() > self._check_transaction_status(self.transaction_status) *-- > transection status after executing the query is 0 and expected is 2* > self._save_changed_data() > self._check_transaction_status(self.transaction_status) > > > On Mon, Aug 19, 2019 at 5:50 PM Yosry Muhammad > wrote: > >> Can you send me the error message? Unfortunately there is a problem >> with my machine right now I am unable to investigate it myself, I am very >> sorry for the inconvenience. >> >> On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi < >> akshay.jo...@enterprisedb.com> wrote: >> >>> Hi Yosry >>> >>> We have tried a lot to figure out the issue but didn't find the >>> actual cause. Can you please figure out and send the patch asap, I'll >>> have >>> to create candidate build tomorrow. >>> >>> On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad >>> wrote: >>> Hi Akshay, I am sorry I do not have access to my machine right now. I will try to work on it (and the JS patch) once I get the chance to. On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi < akshay.jo...@enterprisedb.com> wrote: > Hi Yosry > > Test cases are failing on our build machines. When I reviewed your > patch I have run test cases with paramaster "*--pkg > tools.sqleditor.tests*" on multiple database servers and every > time test case has been passed. > > But on build machines we run test cases with parameter "*--pkg > all* *--exclude feature_tests" *on multiple database server and > it fails for second server onwards. I have also tried the same and it > is > failing on my machine too. > > I am debugging the code why it is getting failed, but if you found > any solution please send the patch asap. > > On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < > akshay.jo...@enterprisedb.com> wrote: > >> Thanks patch applied. >> >> On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad < >> yosry...@gmail.com> wrote: >> >>> Hi Hackers, >>> >>> Please find attached a patch including new python test that >>> checks the transaction status after executing queries and saving >>> data when >>> auto-commit is on/off. It also includes some refactoring of >>> previously >>> written python tests. >>> >>> Please review ! >>> Thanks. Regards. >>> >>> -- >>> *Yosry Muhammad Yosry* >>> >>> Computer Engineering student, >>> The Faculty of Engineering, >>> Cairo University (2021). >>> Class representative of CMP 2021. >>> https://www.linkedin.com/in/yosrym93/ >>> >> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited*
Re: Transaction Status Python Tests
Thanks Khushboo, patch applied. It works, I have tested for multiple database servers. On Tue, Aug 20, 2019 at 10:03 AM Khushboo Vashi < khushboo.va...@enterprisedb.com> wrote: > Hi, > > Please find the attached patch to fix the test cases. > > Thanks, > Khushboo > > On Tue, Aug 20, 2019 at 9:52 AM Akshay Joshi < > akshay.jo...@enterprisedb.com> wrote: > >> Hi Yosry >> >> Not able to figure out the cause today as well, I have comment out the >> disable auto commit test cases for Transaction Status. Please look into it >> once you will have some time. >> >> On Mon, Aug 19, 2019 at 6:05 PM Yosry Muhammad >> wrote: >> >>> This behaviour is very strange. Maybe another test running in parallel >>> is enabling auto-commit or commiting the transaction? >>> >>> There is a problem with my machine right now, can you skip this test for >>> this release if the issue is not resolved? >>> >>> Sorry for the inconvenience. >>> >>> On Mon, Aug 19, 2019, 2:30 PM Akshay Joshi < >>> akshay.jo...@enterprisedb.com> wrote: >>> Hi Yosry Test cases with auto commit disabled gets failed for following scenario only: - Run all test cases on more than one server "*--pkg all* *--exclude feature_tests"*. For first sever all the tests passed and for second onwards fail for all. - If you run only sqleditor test cases on multiple server then no issues. Strange behaviour. - We have tried manually on pgAdmin4 and seems the test cases should pass logic seems correct to me. def runTest(self): self._create_test_table() self._set_auto_commit(self.is_auto_commit_enabled) self._execute_select_sql() self._check_transaction_status(self.transaction_status) *-- transection status after executing the query is 0 and expected is 2* self._save_changed_data() self._check_transaction_status(self.transaction_status) On Mon, Aug 19, 2019 at 5:50 PM Yosry Muhammad wrote: > Can you send me the error message? Unfortunately there is a problem > with my machine right now I am unable to investigate it myself, I am very > sorry for the inconvenience. > > On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi < > akshay.jo...@enterprisedb.com> wrote: > >> Hi Yosry >> >> We have tried a lot to figure out the issue but didn't find the >> actual cause. Can you please figure out and send the patch asap, I'll >> have >> to create candidate build tomorrow. >> >> On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad >> wrote: >> >>> Hi Akshay, >>> >>> I am sorry I do not have access to my machine right now. I will try >>> to work on it (and the JS patch) once I get the chance to. >>> >>> On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi < >>> akshay.jo...@enterprisedb.com> wrote: >>> Hi Yosry Test cases are failing on our build machines. When I reviewed your patch I have run test cases with paramaster "*--pkg tools.sqleditor.tests*" on multiple database servers and every time test case has been passed. But on build machines we run test cases with parameter "*--pkg all* *--exclude feature_tests" *on multiple database server and it fails for second server onwards. I have also tried the same and it is failing on my machine too. I am debugging the code why it is getting failed, but if you found any solution please send the patch asap. On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < akshay.jo...@enterprisedb.com> wrote: > Thanks patch applied. > > On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad > wrote: > >> Hi Hackers, >> >> Please find attached a patch including new python test that >> checks the transaction status after executing queries and saving >> data when >> auto-commit is on/off. It also includes some refactoring of >> previously >> written python tests. >> >> Please review ! >> Thanks. Regards. >> >> -- >> *Yosry Muhammad Yosry* >> >> Computer Engineering student, >> The Faculty of Engineering, >> Cairo University (2021). >> Class representative of CMP 2021. >> https://www.linkedin.com/in/yosrym93/ >> > > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246*
Re: Transaction Status Python Tests
Hi, Please find the attached patch to fix the test cases. Thanks, Khushboo On Tue, Aug 20, 2019 at 9:52 AM Akshay Joshi wrote: > Hi Yosry > > Not able to figure out the cause today as well, I have comment out the > disable auto commit test cases for Transaction Status. Please look into it > once you will have some time. > > On Mon, Aug 19, 2019 at 6:05 PM Yosry Muhammad wrote: > >> This behaviour is very strange. Maybe another test running in parallel is >> enabling auto-commit or commiting the transaction? >> >> There is a problem with my machine right now, can you skip this test for >> this release if the issue is not resolved? >> >> Sorry for the inconvenience. >> >> On Mon, Aug 19, 2019, 2:30 PM Akshay Joshi >> wrote: >> >>> Hi Yosry >>> >>> Test cases with auto commit disabled gets failed for following scenario >>> only: >>> >>>- Run all test cases on more than one server "*--pkg all* *--exclude >>>feature_tests"*. For first sever all the tests passed and for >>>second onwards fail for all. >>>- If you run only sqleditor test cases on multiple server then no >>>issues. Strange behaviour. >>>- We have tried manually on pgAdmin4 and seems the test cases should >>>pass logic seems correct to me. >>> >>> def runTest(self): >>> self._create_test_table() >>> self._set_auto_commit(self.is_auto_commit_enabled) >>> self._execute_select_sql() >>> self._check_transaction_status(self.transaction_status) *-- transection >>> status after executing the query is 0 and expected is 2* >>> self._save_changed_data() >>> self._check_transaction_status(self.transaction_status) >>> >>> >>> On Mon, Aug 19, 2019 at 5:50 PM Yosry Muhammad >>> wrote: >>> Can you send me the error message? Unfortunately there is a problem with my machine right now I am unable to investigate it myself, I am very sorry for the inconvenience. On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi < akshay.jo...@enterprisedb.com> wrote: > Hi Yosry > > We have tried a lot to figure out the issue but didn't find the actual > cause. Can you please figure out and send the patch asap, I'll have to > create candidate build tomorrow. > > On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad > wrote: > >> Hi Akshay, >> >> I am sorry I do not have access to my machine right now. I will try >> to work on it (and the JS patch) once I get the chance to. >> >> On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi < >> akshay.jo...@enterprisedb.com> wrote: >> >>> Hi Yosry >>> >>> Test cases are failing on our build machines. When I reviewed your >>> patch I have run test cases with paramaster "*--pkg >>> tools.sqleditor.tests*" on multiple database servers and every time >>> test case has been passed. >>> >>> But on build machines we run test cases with parameter "*--pkg all* >>> *--exclude >>> feature_tests" *on multiple database server and it fails for second >>> server onwards. I have also tried the same and it is failing on my >>> machine >>> too. >>> >>> I am debugging the code why it is getting failed, but if you found >>> any solution please send the patch asap. >>> >>> On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < >>> akshay.jo...@enterprisedb.com> wrote: >>> Thanks patch applied. On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad wrote: > Hi Hackers, > > Please find attached a patch including new python test that checks > the transaction status after executing queries and saving data when > auto-commit is on/off. It also includes some refactoring of previously > written python tests. > > Please review ! > Thanks. Regards. > > -- > *Yosry Muhammad Yosry* > > Computer Engineering student, > The Faculty of Engineering, > Cairo University (2021). > Class representative of CMP 2021. > https://www.linkedin.com/in/yosrym93/ > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246* >>> >>> >>> -- >>> *Thanks & Regards* >>> *Akshay Joshi* >>> >>> *Sr. Software Architect* >>> *EnterpriseDB Software India Private Limited* >>> *Mobile: +91 976-788-8246* >>> >> > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* > >>> >>> -- >>> *Thanks & Regards* >>> *Akshay Joshi* >>> >>> *Sr. Software Architect* >>> *EnterpriseDB Software India Private Limited* >>> *Mobile: +91 976-788-8246* >>> >> > > -- > *Thanks & Regards* >
Re: Transaction Status Python Tests
Hi Yosry Not able to figure out the cause today as well, I have comment out the disable auto commit test cases for Transaction Status. Please look into it once you will have some time. On Mon, Aug 19, 2019 at 6:05 PM Yosry Muhammad wrote: > This behaviour is very strange. Maybe another test running in parallel is > enabling auto-commit or commiting the transaction? > > There is a problem with my machine right now, can you skip this test for > this release if the issue is not resolved? > > Sorry for the inconvenience. > > On Mon, Aug 19, 2019, 2:30 PM Akshay Joshi > wrote: > >> Hi Yosry >> >> Test cases with auto commit disabled gets failed for following scenario >> only: >> >>- Run all test cases on more than one server "*--pkg all* *--exclude >>feature_tests"*. For first sever all the tests passed and for second >>onwards fail for all. >>- If you run only sqleditor test cases on multiple server then no >>issues. Strange behaviour. >>- We have tried manually on pgAdmin4 and seems the test cases should >>pass logic seems correct to me. >> >> def runTest(self): >> self._create_test_table() >> self._set_auto_commit(self.is_auto_commit_enabled) >> self._execute_select_sql() >> self._check_transaction_status(self.transaction_status) *-- transection >> status after executing the query is 0 and expected is 2* >> self._save_changed_data() >> self._check_transaction_status(self.transaction_status) >> >> >> On Mon, Aug 19, 2019 at 5:50 PM Yosry Muhammad >> wrote: >> >>> Can you send me the error message? Unfortunately there is a problem with >>> my machine right now I am unable to investigate it myself, I am very sorry >>> for the inconvenience. >>> >>> On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi < >>> akshay.jo...@enterprisedb.com> wrote: >>> Hi Yosry We have tried a lot to figure out the issue but didn't find the actual cause. Can you please figure out and send the patch asap, I'll have to create candidate build tomorrow. On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad wrote: > Hi Akshay, > > I am sorry I do not have access to my machine right now. I will try to > work on it (and the JS patch) once I get the chance to. > > On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi < > akshay.jo...@enterprisedb.com> wrote: > >> Hi Yosry >> >> Test cases are failing on our build machines. When I reviewed your >> patch I have run test cases with paramaster "*--pkg >> tools.sqleditor.tests*" on multiple database servers and every time >> test case has been passed. >> >> But on build machines we run test cases with parameter "*--pkg all* >> *--exclude >> feature_tests" *on multiple database server and it fails for second >> server onwards. I have also tried the same and it is failing on my >> machine >> too. >> >> I am debugging the code why it is getting failed, but if you found >> any solution please send the patch asap. >> >> On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < >> akshay.jo...@enterprisedb.com> wrote: >> >>> Thanks patch applied. >>> >>> On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad >>> wrote: >>> Hi Hackers, Please find attached a patch including new python test that checks the transaction status after executing queries and saving data when auto-commit is on/off. It also includes some refactoring of previously written python tests. Please review ! Thanks. Regards. -- *Yosry Muhammad Yosry* Computer Engineering student, The Faculty of Engineering, Cairo University (2021). Class representative of CMP 2021. https://www.linkedin.com/in/yosrym93/ >>> >>> >>> -- >>> *Thanks & Regards* >>> *Akshay Joshi* >>> >>> *Sr. Software Architect* >>> *EnterpriseDB Software India Private Limited* >>> *Mobile: +91 976-788-8246* >>> >> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited* >> *Mobile: +91 976-788-8246* >> > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246* >>> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited* >> *Mobile: +91 976-788-8246* >> > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246*
Re: Transaction Status Python Tests
Hi Yosry Test cases with auto commit disabled gets failed for following scenario only: - Run all test cases on more than one server "*--pkg all* *--exclude feature_tests"*. For first sever all the tests passed and for second onwards fail for all. - If you run only sqleditor test cases on multiple server then no issues. Strange behaviour. - We have tried manually on pgAdmin4 and seems the test cases should pass logic seems correct to me. def runTest(self): self._create_test_table() self._set_auto_commit(self.is_auto_commit_enabled) self._execute_select_sql() self._check_transaction_status(self.transaction_status) *-- transection status after executing the query is 0 and expected is 2* self._save_changed_data() self._check_transaction_status(self.transaction_status) On Mon, Aug 19, 2019 at 5:50 PM Yosry Muhammad wrote: > Can you send me the error message? Unfortunately there is a problem with > my machine right now I am unable to investigate it myself, I am very sorry > for the inconvenience. > > On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi > wrote: > >> Hi Yosry >> >> We have tried a lot to figure out the issue but didn't find the actual >> cause. Can you please figure out and send the patch asap, I'll have to >> create candidate build tomorrow. >> >> On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad >> wrote: >> >>> Hi Akshay, >>> >>> I am sorry I do not have access to my machine right now. I will try to >>> work on it (and the JS patch) once I get the chance to. >>> >>> On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi < >>> akshay.jo...@enterprisedb.com> wrote: >>> Hi Yosry Test cases are failing on our build machines. When I reviewed your patch I have run test cases with paramaster "*--pkg tools.sqleditor.tests*" on multiple database servers and every time test case has been passed. But on build machines we run test cases with parameter "*--pkg all* *--exclude feature_tests" *on multiple database server and it fails for second server onwards. I have also tried the same and it is failing on my machine too. I am debugging the code why it is getting failed, but if you found any solution please send the patch asap. On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < akshay.jo...@enterprisedb.com> wrote: > Thanks patch applied. > > On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad > wrote: > >> Hi Hackers, >> >> Please find attached a patch including new python test that checks >> the transaction status after executing queries and saving data when >> auto-commit is on/off. It also includes some refactoring of previously >> written python tests. >> >> Please review ! >> Thanks. Regards. >> >> -- >> *Yosry Muhammad Yosry* >> >> Computer Engineering student, >> The Faculty of Engineering, >> Cairo University (2021). >> Class representative of CMP 2021. >> https://www.linkedin.com/in/yosrym93/ >> > > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246* >>> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited* >> *Mobile: +91 976-788-8246* >> > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246*
Re: Transaction Status Python Tests
This behaviour is very strange. Maybe another test running in parallel is enabling auto-commit or commiting the transaction? There is a problem with my machine right now, can you skip this test for this release if the issue is not resolved? Sorry for the inconvenience. On Mon, Aug 19, 2019, 2:30 PM Akshay Joshi wrote: > Hi Yosry > > Test cases with auto commit disabled gets failed for following scenario > only: > >- Run all test cases on more than one server "*--pkg all* *--exclude >feature_tests"*. For first sever all the tests passed and for second >onwards fail for all. >- If you run only sqleditor test cases on multiple server then no >issues. Strange behaviour. >- We have tried manually on pgAdmin4 and seems the test cases should >pass logic seems correct to me. > > def runTest(self): > self._create_test_table() > self._set_auto_commit(self.is_auto_commit_enabled) > self._execute_select_sql() > self._check_transaction_status(self.transaction_status) *-- transection > status after executing the query is 0 and expected is 2* > self._save_changed_data() > self._check_transaction_status(self.transaction_status) > > > On Mon, Aug 19, 2019 at 5:50 PM Yosry Muhammad wrote: > >> Can you send me the error message? Unfortunately there is a problem with >> my machine right now I am unable to investigate it myself, I am very sorry >> for the inconvenience. >> >> On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi >> wrote: >> >>> Hi Yosry >>> >>> We have tried a lot to figure out the issue but didn't find the actual >>> cause. Can you please figure out and send the patch asap, I'll have to >>> create candidate build tomorrow. >>> >>> On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad >>> wrote: >>> Hi Akshay, I am sorry I do not have access to my machine right now. I will try to work on it (and the JS patch) once I get the chance to. On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi < akshay.jo...@enterprisedb.com> wrote: > Hi Yosry > > Test cases are failing on our build machines. When I reviewed your > patch I have run test cases with paramaster "*--pkg > tools.sqleditor.tests*" on multiple database servers and every time > test case has been passed. > > But on build machines we run test cases with parameter "*--pkg all* > *--exclude > feature_tests" *on multiple database server and it fails for second > server onwards. I have also tried the same and it is failing on my machine > too. > > I am debugging the code why it is getting failed, but if you found any > solution please send the patch asap. > > On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < > akshay.jo...@enterprisedb.com> wrote: > >> Thanks patch applied. >> >> On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad >> wrote: >> >>> Hi Hackers, >>> >>> Please find attached a patch including new python test that checks >>> the transaction status after executing queries and saving data when >>> auto-commit is on/off. It also includes some refactoring of previously >>> written python tests. >>> >>> Please review ! >>> Thanks. Regards. >>> >>> -- >>> *Yosry Muhammad Yosry* >>> >>> Computer Engineering student, >>> The Faculty of Engineering, >>> Cairo University (2021). >>> Class representative of CMP 2021. >>> https://www.linkedin.com/in/yosrym93/ >>> >> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited* >> *Mobile: +91 976-788-8246* >> > > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* > >>> >>> -- >>> *Thanks & Regards* >>> *Akshay Joshi* >>> >>> *Sr. Software Architect* >>> *EnterpriseDB Software India Private Limited* >>> *Mobile: +91 976-788-8246* >>> >> > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* >
Re: Transaction Status Python Tests
Can you send me the error message? Unfortunately there is a problem with my machine right now I am unable to investigate it myself, I am very sorry for the inconvenience. On Mon, Aug 19, 2019, 2:08 PM Akshay Joshi wrote: > Hi Yosry > > We have tried a lot to figure out the issue but didn't find the actual > cause. Can you please figure out and send the patch asap, I'll have to > create candidate build tomorrow. > > On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad wrote: > >> Hi Akshay, >> >> I am sorry I do not have access to my machine right now. I will try to >> work on it (and the JS patch) once I get the chance to. >> >> On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi >> wrote: >> >>> Hi Yosry >>> >>> Test cases are failing on our build machines. When I reviewed your patch >>> I have run test cases with paramaster "*--pkg tools.sqleditor.tests*" >>> on multiple database servers and every time test case has been passed. >>> >>> But on build machines we run test cases with parameter "*--pkg all* >>> *--exclude >>> feature_tests" *on multiple database server and it fails for second >>> server onwards. I have also tried the same and it is failing on my machine >>> too. >>> >>> I am debugging the code why it is getting failed, but if you found any >>> solution please send the patch asap. >>> >>> On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < >>> akshay.jo...@enterprisedb.com> wrote: >>> Thanks patch applied. On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad wrote: > Hi Hackers, > > Please find attached a patch including new python test that checks the > transaction status after executing queries and saving data when > auto-commit > is on/off. It also includes some refactoring of previously written python > tests. > > Please review ! > Thanks. Regards. > > -- > *Yosry Muhammad Yosry* > > Computer Engineering student, > The Faculty of Engineering, > Cairo University (2021). > Class representative of CMP 2021. > https://www.linkedin.com/in/yosrym93/ > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246* >>> >>> >>> -- >>> *Thanks & Regards* >>> *Akshay Joshi* >>> >>> *Sr. Software Architect* >>> *EnterpriseDB Software India Private Limited* >>> *Mobile: +91 976-788-8246* >>> >> > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* >
Re: Transaction Status Python Tests
Hi Yosry We have tried a lot to figure out the issue but didn't find the actual cause. Can you please figure out and send the patch asap, I'll have to create candidate build tomorrow. On Mon, Aug 19, 2019 at 1:22 PM Yosry Muhammad wrote: > Hi Akshay, > > I am sorry I do not have access to my machine right now. I will try to > work on it (and the JS patch) once I get the chance to. > > On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi > wrote: > >> Hi Yosry >> >> Test cases are failing on our build machines. When I reviewed your patch >> I have run test cases with paramaster "*--pkg tools.sqleditor.tests*" on >> multiple database servers and every time test case has been passed. >> >> But on build machines we run test cases with parameter "*--pkg all* >> *--exclude >> feature_tests" *on multiple database server and it fails for second >> server onwards. I have also tried the same and it is failing on my machine >> too. >> >> I am debugging the code why it is getting failed, but if you found any >> solution please send the patch asap. >> >> On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < >> akshay.jo...@enterprisedb.com> wrote: >> >>> Thanks patch applied. >>> >>> On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad >>> wrote: >>> Hi Hackers, Please find attached a patch including new python test that checks the transaction status after executing queries and saving data when auto-commit is on/off. It also includes some refactoring of previously written python tests. Please review ! Thanks. Regards. -- *Yosry Muhammad Yosry* Computer Engineering student, The Faculty of Engineering, Cairo University (2021). Class representative of CMP 2021. https://www.linkedin.com/in/yosrym93/ >>> >>> >>> -- >>> *Thanks & Regards* >>> *Akshay Joshi* >>> >>> *Sr. Software Architect* >>> *EnterpriseDB Software India Private Limited* >>> *Mobile: +91 976-788-8246* >>> >> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited* >> *Mobile: +91 976-788-8246* >> > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246*
Re: Transaction Status Python Tests
Hi Akshay, I am sorry I do not have access to my machine right now. I will try to work on it (and the JS patch) once I get the chance to. On Mon, Aug 19, 2019, 9:49 AM Akshay Joshi wrote: > Hi Yosry > > Test cases are failing on our build machines. When I reviewed your patch I > have run test cases with paramaster "*--pkg tools.sqleditor.tests*" on > multiple database servers and every time test case has been passed. > > But on build machines we run test cases with parameter "*--pkg all* *--exclude > feature_tests" *on multiple database server and it fails for second > server onwards. I have also tried the same and it is failing on my machine > too. > > I am debugging the code why it is getting failed, but if you found any > solution please send the patch asap. > > On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi < > akshay.jo...@enterprisedb.com> wrote: > >> Thanks patch applied. >> >> On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad >> wrote: >> >>> Hi Hackers, >>> >>> Please find attached a patch including new python test that checks the >>> transaction status after executing queries and saving data when auto-commit >>> is on/off. It also includes some refactoring of previously written python >>> tests. >>> >>> Please review ! >>> Thanks. Regards. >>> >>> -- >>> *Yosry Muhammad Yosry* >>> >>> Computer Engineering student, >>> The Faculty of Engineering, >>> Cairo University (2021). >>> Class representative of CMP 2021. >>> https://www.linkedin.com/in/yosrym93/ >>> >> >> >> -- >> *Thanks & Regards* >> *Akshay Joshi* >> >> *Sr. Software Architect* >> *EnterpriseDB Software India Private Limited* >> *Mobile: +91 976-788-8246* >> > > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* >
Re: Transaction Status Python Tests
Hi Yosry Test cases are failing on our build machines. When I reviewed your patch I have run test cases with paramaster "*--pkg tools.sqleditor.tests*" on multiple database servers and every time test case has been passed. But on build machines we run test cases with parameter "*--pkg all* *--exclude feature_tests" *on multiple database server and it fails for second server onwards. I have also tried the same and it is failing on my machine too. I am debugging the code why it is getting failed, but if you found any solution please send the patch asap. On Mon, Aug 19, 2019 at 11:48 AM Akshay Joshi wrote: > Thanks patch applied. > > On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad wrote: > >> Hi Hackers, >> >> Please find attached a patch including new python test that checks the >> transaction status after executing queries and saving data when auto-commit >> is on/off. It also includes some refactoring of previously written python >> tests. >> >> Please review ! >> Thanks. Regards. >> >> -- >> *Yosry Muhammad Yosry* >> >> Computer Engineering student, >> The Faculty of Engineering, >> Cairo University (2021). >> Class representative of CMP 2021. >> https://www.linkedin.com/in/yosrym93/ >> > > > -- > *Thanks & Regards* > *Akshay Joshi* > > *Sr. Software Architect* > *EnterpriseDB Software India Private Limited* > *Mobile: +91 976-788-8246* > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246*
Re: Transaction Status Python Tests
Thanks patch applied. On Sat, Aug 17, 2019 at 6:22 PM Yosry Muhammad wrote: > Hi Hackers, > > Please find attached a patch including new python test that checks the > transaction status after executing queries and saving data when auto-commit > is on/off. It also includes some refactoring of previously written python > tests. > > Please review ! > Thanks. Regards. > > -- > *Yosry Muhammad Yosry* > > Computer Engineering student, > The Faculty of Engineering, > Cairo University (2021). > Class representative of CMP 2021. > https://www.linkedin.com/in/yosrym93/ > -- *Thanks & Regards* *Akshay Joshi* *Sr. Software Architect* *EnterpriseDB Software India Private Limited* *Mobile: +91 976-788-8246*
Transaction Status Python Tests
Hi Hackers, Please find attached a patch including new python test that checks the transaction status after executing queries and saving data when auto-commit is on/off. It also includes some refactoring of previously written python tests. Please review ! Thanks. Regards. -- *Yosry Muhammad Yosry* Computer Engineering student, The Faculty of Engineering, Cairo University (2021). Class representative of CMP 2021. https://www.linkedin.com/in/yosrym93/ diff --git a/web/pgadmin/tools/sqleditor/tests/execute_query_utils.py b/web/pgadmin/tools/sqleditor/tests/execute_query_test_utils.py similarity index 100% rename from web/pgadmin/tools/sqleditor/tests/execute_query_utils.py rename to web/pgadmin/tools/sqleditor/tests/execute_query_test_utils.py diff --git a/web/pgadmin/tools/sqleditor/tests/test_transaction_status.py b/web/pgadmin/tools/sqleditor/tests/test_transaction_status.py new file mode 100644 index 0..b18dcdc62 --- /dev/null +++ b/web/pgadmin/tools/sqleditor/tests/test_transaction_status.py @@ -0,0 +1,336 @@ +## +# +# pgAdmin 4 - PostgreSQL Tools +# +# Copyright (C) 2013 - 2019, The pgAdmin Development Team +# This software is released under the PostgreSQL Licence +# +## + +import json +import random + +from pgadmin.browser.server_groups.servers.databases.tests import utils as \ +database_utils +from pgadmin.utils.route import BaseTestGenerator +from regression import parent_node_dict +from regression.python_test_utils import test_utils as utils +from pgadmin.tools.sqleditor.tests.execute_query_test_utils import execute_query + +from pgadmin.tools.sqleditor.utils.constant_definition \ +import TX_STATUS_IDLE, TX_STATUS_INTRANS + + +class TestTransactionControl(BaseTestGenerator): +""" This class will test the transaction status after various operations """ +scenarios = [ +('When auto-commit is enabled, and save is successful', dict( +is_auto_commit_enabled=True, +transaction_status=TX_STATUS_IDLE, +save_payload={ +"updated": {}, +"added": { +"2": { +"err": False, +"data": { +"pk_col": "3", +"__temp_PK": "2", +"normal_col": "three" +} +} +}, +"staged_rows": {}, +"deleted": {}, +"updated_index": {}, +"added_index": {"2": "2"}, +"columns": [ +{ +"name": "pk_col", +"display_name": "pk_col", +"column_type": "[PK] integer", +"column_type_internal": "integer", +"pos": 0, +"label": "pk_col[PK] integer", +"cell": "number", +"can_edit": True, +"type": "integer", +"not_null": True, +"has_default_val": False, +"is_array": False}, +{"name": "normal_col", + "display_name": "normal_col", + "column_type": "character varying", + "column_type_internal": "character varying", + "pos": 1, + "label": "normal_colcharacter varying", + "cell": "string", + "can_edit": True, + "type": "character varying", + "not_null": False, + "has_default_val": False, + "is_array": False} +] +} +)), +('When auto-commit is disabled and save is successful', dict( +is_auto_commit_enabled=False, +transaction_status=TX_STATUS_INTRANS, +save_payload={ +"updated": {}, +"added": { +"2": { +"err": False, +"data": { +"pk_col": "3", +"__temp_PK": "2", +"normal_col": "three" +} +} +}, +"staged_rows": {}, +"deleted": {}, +"updated_index": {}, +"added_index": {"2": "2"}, +"columns": [ +{ +"name": "pk_col", +"display_name": "pk_col", +"column_type": "[PK] integer", +"column_type_internal": "integer", +"pos": 0, +"label": "pk_col[PK]