CN112069060A - Data processing method and device, electronic equipment and storage medium - Google Patents

Data processing method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN112069060A
CN112069060A CN202010814514.6A CN202010814514A CN112069060A CN 112069060 A CN112069060 A CN 112069060A CN 202010814514 A CN202010814514 A CN 202010814514A CN 112069060 A CN112069060 A CN 112069060A
Authority
CN
China
Prior art keywords
data
url
character string
debugging
page
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010814514.6A
Other languages
Chinese (zh)
Inventor
张文哲
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Dajia Internet Information Technology Co Ltd
Original Assignee
Beijing Dajia Internet Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Dajia Internet Information Technology Co Ltd filed Critical Beijing Dajia Internet Information Technology Co Ltd
Priority to CN202010814514.6A priority Critical patent/CN112069060A/en
Publication of CN112069060A publication Critical patent/CN112069060A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/362Software debugging
    • G06F11/3644Software debugging by instrumenting at runtime
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Preventing errors by testing or debugging software
    • G06F11/362Software debugging
    • G06F11/366Software debugging using diagnostics

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The present disclosure relates to a data processing method, an apparatus, an electronic device, and a storage medium, the method including: in the process of debugging the application program, determining the name of data to be displayed on a debugging page; acquiring data content corresponding to the data name; and displaying the data name and the data content corresponding to the data name in the debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.

Description

Data processing method and device, electronic equipment and storage medium
Technical Field
The present application relates to the field of software testing technologies, and in particular, to a data processing method and apparatus, an electronic device, and a storage medium.
Background
In the process of front-end development of an application program, program debugging needs to be carried out on a real machine such as a mobile phone. During the debugging process of the application program, if a tester encounters a bug, the tester needs to find out the reason, and at this time, the tester needs to search the reason from several dimensions such as a test address, parameters, a cache and the like.
However, in the related art, data such as a test address, a parameter, a cache and the like cannot be seen in a mobile phone page, and the data can only be acquired in a packet capturing manner each time, so that the efficiency of finding a bug cause is low, and the debugging efficiency of an application program is low.
Disclosure of Invention
In order to solve the technical problems of low efficiency of finding a bug cause and low debugging efficiency of an application program in the related art, the embodiment of the disclosure provides a data processing method, a data processing device, an electronic device and a storage medium, and the technical scheme of the disclosure is as follows:
according to a first aspect of the embodiments of the present disclosure, there is provided a data processing method, including:
in the process of debugging the application program, determining the name of data to be displayed on a debugging page;
acquiring data content corresponding to the data name;
and displaying the data name and the data content corresponding to the data name in the debugging page.
Optionally, the data name includes a uniform resource locator URL of the debug page, and a URL parameter of the URL;
the acquiring of the data content corresponding to the data name includes:
acquiring a URL character string of the debugging page;
segmenting the URL character string through a character string segmentation function to obtain a sub URL character string array included by the URL character string;
segmenting the sub URL character string data through the character string segmentation function to obtain key values and corresponding value values of all sub URL character strings in the sub URL character string array;
and determining the URL character strings as the data content of the URL, and determining the key value and the corresponding value of each sub-URL character string as the data content of the URL parameter.
Optionally, the data name includes a cache cookie of the debug page;
the acquiring of the data content corresponding to the data name includes:
acquiring a cookie character string of the debugging page;
segmenting the cookie character string through a character string segmentation function to obtain a sub cookie character string array included by the cookie character string;
segmenting the sub cookie character string data through the character string segmentation function to obtain key values and corresponding value values of each sub cookie character string in the sub cookie character string array;
and determining the key value and the corresponding value of each sub-cookie character string as the data content of the cookie.
Optionally, a user-defined component is arranged in the debugging page;
the method further comprises the following steps:
when receiving the triggering operation of a user on the self-defining component, determining a target function to be executed by calling a first parameter field of the self-defining component, and executing the target function;
and determining the text content to be displayed on the self-defined component by calling a second parameter field of the self-defined component, and displaying the text content on the self-defined component.
Optionally, a copy component is arranged in the debugging page;
the method further comprises the following steps:
when a triggering operation of a user on the copying component is received, displaying a data content input area in the debugging page;
and copying the data content to be copied to the data content input area.
Optionally, a refresh component is arranged in the debugging page;
the method further comprises the following steps:
when the triggering operation of a user on the refreshing component is received, detecting whether the data name currently displayed in the debugging page and the data content corresponding to the data name are updated or not;
and if the currently displayed data name in the debugging page and the data content corresponding to the data name are updated, displaying the updated data name and the data content corresponding to the data name in the debugging page.
Optionally, a theme switching component is arranged in the debugging page;
the method further comprises the following steps:
setting a theme self-defining variable for the theme switching component;
and adjusting the style of the current theme by adjusting the variable value of the self-defined variable, and adjusting the brightness of the debugging page to the brightness corresponding to the style of the current theme.
According to a second aspect of the embodiments of the present disclosure, there is provided a data processing apparatus including:
the data name determining module is configured to determine the name of the data to be displayed on a debugging page in the process of debugging the application program;
the data content acquisition module is configured to execute acquisition of data content corresponding to the data name;
and the data display module is configured to display the data name and the data content corresponding to the data name in the debugging page.
Optionally, the data name includes a uniform resource locator URL of the debug page, and a URL parameter of the URL;
the data content obtaining module is specifically configured to perform:
acquiring a URL character string of the debugging page;
segmenting the URL character string through a character string segmentation function to obtain a sub URL character string array included by the URL character string;
segmenting the sub URL character string data through the character string segmentation function to obtain key values and corresponding value values of all sub URL character strings in the sub URL character string array;
and determining the URL character strings as the data content of the URL, and determining the key value and the corresponding value of each sub-URL character string as the data content of the URL parameter.
Optionally, the data name includes a cache cookie of the debug page;
the data content obtaining module is specifically configured to perform:
acquiring a cookie character string of the debugging page;
segmenting the cookie character string through a character string segmentation function to obtain a sub cookie character string array included by the cookie character string;
segmenting the sub cookie character string data through the character string segmentation function to obtain key values and corresponding value values of each sub cookie character string in the sub cookie character string array;
and determining the key value and the corresponding value of each sub-cookie character string as the data content of the cookie.
Optionally, a user-defined component is arranged in the debugging page;
the device further comprises:
the target function execution module is configured to execute a target function to be executed by calling a first parameter field of the custom assembly when the trigger operation of the user on the custom assembly is received, and execute the target function;
the text content display module is configured to determine text content to be displayed on the self-defined component by calling the second parameter field of the self-defined component, and display the text content on the self-defined component.
Optionally, a copy component is arranged in the debugging page;
the device further comprises:
an input area display module configured to execute displaying a data content input area in the debugging page when a trigger operation of a user on the copying component is received;
a data content copying module configured to perform copying of data content to be copied to the data content input area.
Optionally, a refresh component is arranged in the debugging page;
the device further comprises:
the data content detection module is configured to detect whether the data name currently displayed in the debugging page and the data content corresponding to the data name are updated or not when the triggering operation of the user on the refreshing component is received;
and the data content updating module is configured to execute that if the data name currently displayed in the debugging page and the data content corresponding to the data name are updated, the updated data name and the data content corresponding to the data name are displayed in the debugging page.
Optionally, a theme switching component is arranged in the debugging page;
the device further comprises:
a variable setting module configured to perform setting of a theme customization variable for the theme switching component;
and the theme adjusting module is configured to adjust the style of the current theme by adjusting the variable value of the custom variable, and adjust the brightness of the debugging page to the brightness corresponding to the style of the current theme.
According to a third aspect of the embodiments of the present disclosure, there is provided an electronic apparatus including:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the data processing method of the first aspect.
According to a fourth aspect of embodiments of the present disclosure, there is provided a storage medium, wherein instructions that, when executed by a processor of an electronic device, enable the electronic device to perform the data processing method of the first aspect.
According to a fifth aspect of embodiments of the present disclosure, there is provided a computer program product containing instructions which, when run on a computer, cause the computer to carry out the data processing method of the first aspect.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
Drawings
FIG. 1 is a flow diagram illustrating a method of data processing in accordance with an exemplary embodiment;
FIG. 2 is a flowchart of one implementation of step S12 in the embodiment of FIG. 1;
FIG. 3 is a flowchart of another implementation of step S12 in the embodiment shown in FIG. 1;
FIG. 4 is a flow chart illustrating another data processing method according to an example embodiment
FIG. 5 is a schematic diagram illustrating a data visualization panel in accordance with an exemplary embodiment;
FIG. 6 is a block diagram illustrating a data processing apparatus in accordance with an exemplary embodiment;
FIG. 7 is a block diagram illustrating an electronic device in accordance with an exemplary embodiment;
FIG. 8 is a block diagram illustrating an apparatus for processing data in accordance with an exemplary embodiment;
fig. 9 is a block diagram illustrating another apparatus for processing data according to an example embodiment.
Detailed Description
In order to make the technical solutions of the present disclosure better understood by those of ordinary skill in the art, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the above-described drawings are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the disclosure described herein are capable of operation in sequences other than those illustrated or otherwise described herein. The implementations described in the exemplary embodiments below are not intended to represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present disclosure, as detailed in the appended claims.
In order to solve the technical problems of low efficiency of finding a bug cause and low application program debugging efficiency in the related art, the embodiments of the present disclosure provide a data processing method, an apparatus, an electronic device, and a storage medium.
In a first aspect, a data processing method provided by the embodiments of the present disclosure will be described in detail.
As shown in fig. 1, a data processing method provided in an embodiment of the present disclosure may include the following steps:
in step S11, in the process of debugging the application program, the name of the data to be presented on the debug page is determined.
Specifically, in the process of debugging the application program, if a tester encounters a bug and needs to find out the reason, the tester needs to search the reason from several dimensions such as a test address URL, URL parameters, a cache cookie and the like. In order to facilitate a tester to efficiently obtain data of several dimensions, such as a test address URL, a URL parameter, a cache cookie, and the like, the determined data name of the data to be displayed on the debug page may include: URL, URL parameters, and cache cookies.
Of course, in practical applications, the name of the data to be displayed on the debug page may be determined according to specific situations, and the data name may also be: the system time. The data name to be displayed on the debugging page is not specifically limited in the embodiment of the disclosure.
In step S12, the data content corresponding to the data name is acquired.
After the data names to be displayed on the debugging page are determined, the data content of each data name needs to be acquired, so that each data name and the data content corresponding to the data name are displayed in the debugging page in the subsequent steps.
For example, when the data name is a URL, the data content corresponding to the data name may be: http:// test. corp. kuaisou. com:8080/wzry _ sliblst? widget _ anchorage 3x94ew6ffkyd9hy & source kwai.
When the data name is a URL parameter, the data content corresponding to the data name may be: widget _ anchorid: 3x94ew6 ffk; and, source: kwai.
When the data name is the system time, the data content corresponding to the data name may be: mon,01Jun 202003: 44:54 GMT.
When the data name is a cookie, the data content corresponding to the data name can be [ client _ key ]:56c3713 c; (iii) [ kpn ] KUAISHOU; (token) f679650d76754f7795f7e65ab83060d 1-229339376; web 635465063FA98B 44; [ ksCorpDeviceid ] db11eod3-ae60-4f5b-b486-6c5 c.
Of course, the data names and the data contents corresponding to the data names are described above by way of example only, and in practical applications, the data contents corresponding to the same data name may be different for different debugging pages.
For clarity of description of the scheme, a detailed implementation of acquiring data content corresponding to the data name will be described in detail in the following examples.
In step S13, the data name and the data content corresponding to the data name are displayed on the debug page.
Specifically, after the data names to be displayed on the debugging page and the data contents corresponding to the data names are acquired, the data names and the data contents corresponding to the data names can be displayed on the debugging page through the method provided by vue, so that a data visualization panel is formed.
It should be noted that the data name and the display form of the data content corresponding to the data name in the debugging page may be determined according to an actual situation, which is not specifically limited in the embodiment of the present disclosure.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
For clarity of description of the scheme, a detailed implementation of acquiring data content corresponding to a data name will be described in detail in the following examples.
In one embodiment, the data name includes a uniform resource locator, URL, of the debug page, and a URL parameter of the URL.
At this time, acquiring the data content corresponding to the data name, as shown in fig. 2, may include the following steps:
in step S21, a URL string of the debug page is acquired.
Specifically, each debugging page corresponds to one URL string, and therefore, the URL string of the debugging page can be obtained in a window.
For example, the URL string may be http:// test. cord. kuaisou. com:8080/wzry _ sliblst? widget _ anchorage 3x94ew6ffkyd9hy & source kwai.
In step S22, the URL string is segmented by a string segmentation function, so as to obtain a sub-URL string array included in the URL string.
Specifically, when the URL string of the debugging page is obtained, the string of the parameter part in the URL string of the page may be obtained by a window. Wherein the question mark is an identification of the beginning of the parameter.
For example, when the URL string is http:// test. cord. kuaisou. com:8080/wzry _ sliblst? Get "? "the following part is widget _ appended ═ 3x94ew6ffkyd9hy & source ═ kwai, that is, the URL string includes the sub URL string array of widget _ appended ═ 3x94ew6ffkyd9hy & source ═ kwai.
In step S23, the sub URL string data is segmented by the string segmentation function, so as to obtain the key value and the corresponding value of each sub URL string in the sub URL string array.
Specifically, after obtaining a sub-URL string array included in the URL string, the URL string data may be segmented by a string segmentation function, specifically, the string segmentation function may distinguish parameter portions around each symbol to obtain each sub-URL string in the sub-URL string array, and continue segmenting each sub-URL string by the string segmentation function, where the left portion is a key value of one sub-URL string, and the right portion is a value of one URL string.
For example, the URL string includes a sub-URL string array of 3 × 94ew6ffkyd9hy & source kwai.
Firstly, the parameter parts around the symbol are separated by a character string segmentation function to obtain two sub URL character strings, namely widget _ anchor 3x94ew6ffkyd9hy and source kwai.
Then, each substring is cut by a string cutting function into a left part and a right part, the left part is a key value of the array of the substring, and the right part is a value of the array of the substring.
For example, for the sub URL string widget _ anchor of 3x94ew6ffkyd9hy, the key value of the sub URL string is widget _ anchor, and the value of the sub URL string is 3x94ew6ffkyd9 hy.
For a child URL string source kwai, the key value of the child URL string is source, and the value of the child URL string is kwai.
In step S24, the URL character strings are determined as the data content of the URL, and the key value and the corresponding value of each sub-URL character string are determined as the data content of the URL parameter.
In order to accurately display the URL and the URL parameters in the debugging page subsequently, the acquired URL character string can be assigned to the URL, namely the URL character string is determined as the data content of the URL; and assigning the key value and the corresponding value of each sub-URL character string to the URL parameter, namely determining the key value and the corresponding value of each sub-URL character string as the data content of the URL parameter.
Therefore, by the technical scheme provided by the embodiment, the URL of the debugging page and the data content corresponding to the URL can be accurately acquired; the URL of the debugging page and the data content corresponding to the URL, and the data content corresponding to the URL parameter can be accurately acquired, so that in the subsequent steps, the URL of the debugging page and the data content corresponding to the URL are displayed in the debugging page, and thus, when a tester encounters a bug, the tester can directly check the URL and the data content corresponding to the URL, the URL parameter and the data content corresponding to the URL parameter in the debugging page, and the tester is favorable for rapidly analyzing the bug occurrence reason from the dimension of the testing address of the debugging page.
In another embodiment, the data name comprises a cache cookie for the debug page.
At this time, acquiring the data content corresponding to the data name, as shown in fig. 3, may include the following steps:
in step S31, a cookie string of the debug page is acquired.
In step S32, the cookie string is segmented by a string segmentation function, so as to obtain a sub-cookie string array included in the cookie string.
In step S33, the sub cookie string data is segmented by the string segmentation function, so as to obtain a key value and a corresponding value of each sub cookie string in the sub cookie string array.
In step S34, the key value and the corresponding value of each substring are determined as the data content of the cookie.
Specifically, when the data name includes a cache cookie of the debug page, all cookie character strings in the debug page may be acquired in a document cookie manner, and the format of the acquired cookie character strings in actual application is the same as that of the URL character strings in the embodiment shown in fig. 2, and the data content of the cookie may be acquired in the same manner as in the embodiment shown in fig. 2.
Since how to acquire the data content of the URL parameter has been elaborated in detail in the embodiment shown in fig. 2, the process of acquiring the data content of the cookie is not described herein again.
On the basis of the above embodiment, in an implementation manner, a custom component is set in a debug page, and can be referred by way of vue components, and two parameter fields, outfn and outprep, can be defined on the custom component, where the parameter field of outfn is used to determine an objective function triggered by the custom component; and the outProp parameter field is used to determine the textual content displayed on the custom component.
At this time, as shown in fig. 4, the data processing method may further include the steps of:
in step S14, when a triggering operation of the custom component by the user is received, the target function to be executed is determined by calling the first parameter field of the custom component, and the target function is executed.
When receiving the triggering operation of the user on the custom component, the target function to be executed can be determined by calling a first parameter field of the custom component, such as an outfn parameter field, and the target function is executed. Therefore, the target function can be customized and executed by setting the custom component in the debugging page, and the testing efficiency of the application program is improved.
In step S15, the text content to be displayed on the custom component is determined by calling the second parameter field of the custom component, and the text content is displayed on the custom component.
Specifically, when the target function is executed, the text content to be displayed on the custom component and the text content displayed on the custom component can be determined by calling a second parameter field of the custom component, such as an outProp parameter field, and the text content can be directly displayed in the custom component through bidirectional data binding.
Therefore, according to the technical scheme provided by the embodiment, the target function can be customized and executed by setting the custom component in the debugging page, so that when only a certain interface is tested or a certain specific behavior is carried out, the test of the certain interface or the characteristic behavior can be quickly realized by executing the corresponding target function, and the test efficiency is further improved.
On the basis of the foregoing embodiment, in an embodiment, a copy component is further disposed in the debug page, in this case, the data processing method may further include the following steps, which are respectively step a1 to step a 3:
step a1, when receiving the trigger operation of the copy component by the user, displaying the data content input area in the debugging page.
Specifically, there may be a plurality of copy components set in the debug page, and specifically, one copy component may be set for each data content, so that it is convenient to copy each data content in the subsequent steps.
When a tester wants to copy the data content of the debugging page, a trigger operation may be performed on the copy component corresponding to the data content, where the trigger operation may be a single click or a double click, and the trigger operation is not specifically limited in the embodiment of the disclosure.
When a trigger operation of the copy component by the user is received, a data content input area can be displayed in the debugging page, for example, a data content input box can be displayed in the debugging page.
Step a2, copying the data content to be copied to the data content input area.
Specifically, the data content to be copied may be stored in a value, and copied to the data content input area by an execcoommand method provided by the browser.
Therefore, according to the technical scheme provided by the embodiment of the disclosure, by arranging the copying component in the debugging page, a tester can copy the data content as required, and the testing efficiency of the application program is improved.
On the basis of the above embodiment, in one embodiment, a refresh component is arranged in the debugging page; at this time, the data processing method may further include the steps of step b1 and step b2, respectively:
step b1, when receiving the trigger operation of the user to the refresh component, detecting whether the data name currently displayed in the debugging page and the data content corresponding to the data name are updated.
Step b2, if the data name currently displayed in the debugging page and the data content corresponding to the data name are updated, displaying the updated data name and the data content corresponding to the data name in the debugging page.
Specifically, when a tester needs to refresh data in a debugging page, a trigger operation may be performed on a refresh component, and when a trigger operation of a user on the refresh component is received, page refresh may be triggered by a window.
Therefore, the refreshing component is arranged in the debugging page, so that a tester can conveniently execute refreshing operation on the data displayed in the debugging page, the debugging page is not required to be refreshed only by exiting the reentry mode like the prior art, and the testing efficiency is further improved.
On the basis of the foregoing embodiment, in an embodiment, a theme switching component is further disposed in the debug page, in this case, the data processing method may further include the following steps, which are step c1 and step c2, respectively:
and step c1, setting theme self-defining variables for the theme switching component.
And c2, adjusting the style of the current theme by adjusting the variable value of the custom variable, and adjusting the brightness of the debugging page to the brightness corresponding to the style of the current theme.
In this embodiment, through bi-directional data binding at vue, a subject custom variable is defined, which is: light and dark, different theme self-defining variables correspond to different theme styles, that is, the light and dark have different theme styles, and the brightness of the debugging pages corresponding to the different theme styles is different.
Specifically, when the custom variable is light, the style of the current theme is adjusted to the theme style corresponding to light, and the brightness of the debugging page is adjusted to the brightness of the theme style corresponding to light. And when the custom variable is dark, adjusting the style of the current theme to be the theme style corresponding to dark, and adjusting the brightness of the debugging page to be the brightness of the theme style corresponding to dark.
Therefore, by arranging the theme switching assembly in the debugging page, a tester can switch and switch the theme of the debugging page according to the requirement.
For clarity of description, the data processing method will be described below with reference to specific examples. Fig. 5 is a schematic diagram of a data visualization panel.
As can be seen from fig. 5, the data visualization panel can display a PAGE URL, that is, a URL of the debugging PAGE, and data content corresponding to the URL; URL PARAMS, namely URL parameters and data content corresponding to the URL PARAMS; SYSTEM DATE, system time and corresponding data content; COOKIE and corresponding data content; a refreshing page, namely a refreshing component is also arranged; initializing an interface, namely a self-defining component; COPY component; and the upper left corner is provided with a Go Dark same Theme switching component.
By forming the datamation visual panel, when a tester tests a program, if the tester encounters a bug, reasons can be quickly searched from several dimensions such as a test address URL, URL parameters, cache and the like, and the test efficiency of a debugging page can be improved by setting a refreshing component, a self-defining component, a copying component and a theme switching component.
According to a second aspect of the embodiments of the present disclosure, there is provided a data processing apparatus, as shown in fig. 6, including:
the data name determining module 610 is configured to determine a data name to be displayed on a debugging page in the process of debugging the application program;
a data content obtaining module 620 configured to perform obtaining data content corresponding to the data name;
630 configured to perform displaying the data name and the data content corresponding to the data name in the debugging page.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
Optionally, the data name includes a uniform resource locator URL of the debug page, and a URL parameter of the URL;
the data content obtaining module is specifically configured to perform:
acquiring a URL character string of the debugging page;
segmenting the URL character string through a character string segmentation function to obtain a sub URL character string array included by the URL character string;
segmenting the sub URL character string data through the character string segmentation function to obtain key values and corresponding value values of all sub URL character strings in the sub URL character string array;
and determining the URL character strings as the data content of the URL, and determining the key value and the corresponding value of each sub-URL character string as the data content of the URL parameter.
Optionally, the data name includes a cache cookie of the debug page;
the data content obtaining module is specifically configured to perform:
acquiring a cookie character string of the debugging page;
segmenting the cookie character string through a character string segmentation function to obtain a sub cookie character string array included by the cookie character string;
segmenting the sub cookie character string data through the character string segmentation function to obtain key values and corresponding value values of each sub cookie character string in the sub cookie character string array;
and determining the key value and the corresponding value of each sub-cookie character string as the data content of the cookie.
Optionally, a user-defined component is arranged in the debugging page;
the device further comprises:
the target function execution module is configured to execute a target function to be executed by calling a first parameter field of the custom assembly when the trigger operation of the user on the custom assembly is received, and execute the target function;
the text content display module is configured to determine text content to be displayed on the self-defined component by calling the second parameter field of the self-defined component, and display the text content on the self-defined component.
Optionally, a copy component is arranged in the debugging page;
the device further comprises:
an input area display module configured to execute displaying a data content input area in the debugging page when a trigger operation of a user on the copying component is received;
a data content copying module configured to perform copying of data content to be copied to the data content input area.
Optionally, a refresh component is arranged in the debugging page;
the device further comprises:
the data content detection module is configured to detect whether the data name currently displayed in the debugging page and the data content corresponding to the data name are updated or not when the triggering operation of the user on the refreshing component is received;
and the data content updating module is configured to execute that if the data name currently displayed in the debugging page and the data content corresponding to the data name are updated, the updated data name and the data content corresponding to the data name are displayed in the debugging page.
Optionally, a theme switching component is arranged in the debugging page;
the device further comprises:
a variable setting module configured to perform setting of a theme customization variable for the theme switching component;
and the theme adjusting module is configured to adjust the style of the current theme by adjusting the variable value of the custom variable, and adjust the brightness of the debugging page to the brightness corresponding to the style of the current theme.
According to a third aspect of the embodiments of the present disclosure, there is provided an electronic apparatus, as shown in fig. 7, including:
a processor 710;
a memory 720 for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the data processing method of the first aspect.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
Fig. 8 is a block diagram illustrating an apparatus 800 for processing data according to an example embodiment. For example, the apparatus 800 may be provided as a server. Referring to FIG. 8, the apparatus 800 includes a processing component 822, which further includes one or more processors, and memory resources, represented by memory 832, for storing instructions, such as applications, that are executable by the processing component 822. The application programs stored in memory 832 may include one or more modules that each correspond to a set of instructions. Further, the processing component 822 is configured to execute instructions to perform the data processing method according to the first aspect.
The device 800 may also include a power component 826 configured to perform power management of the device 800, a wired or wireless network interface 850 configured to connect the device 800 to a network, and an input/output (I/O) interface 858. The apparatus 800 may operate based on an operating system stored in the memory 832, such as Windows Server, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM, or the like.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
Fig. 9 is a block diagram illustrating an apparatus 900 for processing data according to an example embodiment. For example, the apparatus 900 may be a mobile phone, a computer, a digital broadcast electronic device, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 9, apparatus 900 may include one or more of the following components: a processing component 902, a memory 904, a power component 906, a multimedia component 908, an audio component 910, an input/output (I/O) interface 912, a sensor component 914, and a communication component 916.
The processing component 902 generally controls overall operation of the device 900, such as operations associated with display, telephone calls, data communications, camera operations, and recording operations. Processing component 902 may include one or more processors 920 to execute instructions to perform all or a portion of the steps of the methods described above. Further, processing component 902 can include one or more modules that facilitate interaction between processing component 902 and other components. For example, the processing component 902 can include a multimedia module to facilitate interaction between the multimedia component 908 and the processing component 902.
The memory 904 is configured to store various types of data to support operation at the device 900. Examples of such data include instructions for any application or method operating on device 900, contact data, phonebook data, messages, pictures, videos, and so forth. The memory 904 may be implemented by any type or combination of volatile or non-volatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disks.
A power supply component 907 provides power to the various components of the device 900. The power components 907 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 900.
The multimedia component 908 comprises a screen providing an output interface between the device 900 and a user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive an input signal from a user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundary of a touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 908 includes a front facing camera and/or a rear facing camera. The front-facing camera and/or the rear-facing camera may receive external multimedia data when the device 900 is in an operating mode, such as a shooting mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
The audio component 910 is configured to output and/or input audio signals. For example, audio component 910 includes a Microphone (MIC) configured to receive external audio signals when apparatus 900 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may further be stored in the memory 404 or transmitted via the communication component 916. In some embodiments, audio component 910 also includes a speaker for outputting audio signals.
I/O interface 912 provides an interface between processing component 902 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: a home button, a volume button, a start button, and a lock button.
The sensor component 914 includes one or more sensors for providing status assessment of various aspects of the apparatus 900. For example, the sensor assembly 914 may detect an open/closed state of the device 900, the relative positioning of the components, such as a display and keypad of the apparatus 900, the sensor assembly 914 may also detect a change in the position of the apparatus 900 or a component of the apparatus 900, the presence or absence of user contact with the apparatus 900, orientation or acceleration/deceleration of the apparatus 900, and a change in the temperature of the apparatus 900. The sensor assembly 914 may include a proximity sensor configured to detect the presence of a nearby object in the absence of any physical contact. The sensor assembly 914 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 914 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 916 is configured to facilitate communications between the apparatus 900 and other devices in a wired or wireless manner. The apparatus 900 may access a wireless network based on a communication standard, such as WiFi, an operator network (such as 2G, 3G, 4G, or 5G), or a combination thereof. In an exemplary embodiment, the communication component 416 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 916 further includes a Near Field Communication (NFC) module to facilitate short-range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, Ultra Wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the apparatus 900 may be implemented by one or more Application Specific Integrated Circuits (ASICs), Digital Signal Processors (DSPs), Digital Signal Processing Devices (DSPDs), Programmable Logic Devices (PLDs), Field Programmable Gate Arrays (FPGAs), controllers, micro-controllers, microprocessors or other electronic components for performing the data processing method described in the first aspect.
In an exemplary embodiment, a non-transitory computer readable storage medium comprising instructions, such as the memory 904 comprising instructions, executable by the processor 920 of the apparatus 900 to perform the above-described method is also provided. Alternatively, for example, the storage medium may be a non-transitory computer-readable storage medium, such as a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
According to an eighth aspect of embodiments of the present disclosure, there is provided a storage medium, wherein instructions that, when executed by a processor of an electronic device, enable the electronic device to perform the data processing method of the first aspect.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
According to a tenth aspect of embodiments of the present disclosure, there is provided a computer program product containing instructions which, when run on a computer, cause the computer to carry out the data processing method of the first aspect.
In the technical scheme provided by the embodiment of the disclosure, in the process of debugging an application program, the data name of data to be displayed on a debugging page is determined; acquiring data content corresponding to the data name; and finally, displaying the data name and the data content corresponding to the data name in a debugging page. Therefore, according to the technical scheme provided by the embodiment of the disclosure, the data visualization panel is provided, and data to be displayed on the debugging page and data content are displayed in the data visualization panel, so that when a tester encounters a bug and needs to find out the reason, the tester can directly check the data in the data visualization panel and find out the reason of the bug, unlike the related technology, the tester needs to acquire the data in a packet capturing manner to find out the reason of the bug, so that the efficiency of finding out the reason of the bug can be improved, and the debugging efficiency of the application program is improved.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This application is intended to cover any variations, uses, or adaptations of the disclosure following, in general, the principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It will be understood that the present disclosure is not limited to the precise arrangements described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (10)

1. A data processing method, comprising:
in the process of debugging the application program, determining the name of data to be displayed on a debugging page;
acquiring data content corresponding to the data name;
and displaying the data name and the data content corresponding to the data name in the debugging page.
2. The method of claim 1, wherein the data name comprises a uniform resource locator, URL, of the debug page, and a URL parameter of the URL;
the acquiring of the data content corresponding to the data name includes:
acquiring a URL character string of the debugging page;
segmenting the URL character string through a character string segmentation function to obtain a sub URL character string array included by the URL character string;
segmenting the sub URL character string data through the character string segmentation function to obtain key values and corresponding value values of all sub URL character strings in the sub URL character string array;
and determining the URL character strings as the data content of the URL, and determining the key value and the corresponding value of each sub-URL character string as the data content of the URL parameter.
3. The method of claim 1, wherein the data name comprises a cache cookie for the debug page;
the acquiring of the data content corresponding to the data name includes:
acquiring a cookie character string of the debugging page;
segmenting the cookie character string through a character string segmentation function to obtain a sub cookie character string array included by the cookie character string;
segmenting the sub cookie character string data through the character string segmentation function to obtain key values and corresponding value values of each sub cookie character string in the sub cookie character string array;
and determining the key value and the corresponding value of each sub-cookie character string as the data content of the cookie.
4. The method according to any one of claims 1 to 3, wherein a custom component is provided in the debugging page;
the method further comprises the following steps:
when receiving the triggering operation of a user on the self-defining component, determining a target function to be executed by calling a first parameter field of the self-defining component, and executing the target function;
and determining the text content to be displayed on the self-defined component by calling a second parameter field of the self-defined component, and displaying the text content on the self-defined component.
5. The method according to any one of claims 1 to 3, wherein a copy component is provided in the debug page;
the method further comprises the following steps:
when a triggering operation of a user on the copying component is received, displaying a data content input area in the debugging page;
and copying the data content to be copied to the data content input area.
6. The method according to any one of claims 1 to 3, wherein a refresh component is disposed in the debug page;
the method further comprises the following steps:
when the triggering operation of a user on the refreshing component is received, detecting whether the data name currently displayed in the debugging page and the data content corresponding to the data name are updated or not;
and if the currently displayed data name in the debugging page and the data content corresponding to the data name are updated, displaying the updated data name and the data content corresponding to the data name in the debugging page.
7. The method according to any one of claims 1 to 3, wherein a theme switching component is arranged in the debugging page;
the method further comprises the following steps:
setting a theme self-defining variable for the theme switching component;
and adjusting the style of the current theme by adjusting the variable value of the self-defined variable, and adjusting the brightness of the debugging page to the brightness corresponding to the style of the current theme.
8. A data processing apparatus, comprising:
the data name determining module is configured to determine the name of the data to be displayed on a debugging page in the process of debugging the application program;
the data content acquisition module is configured to execute acquisition of data content corresponding to the data name;
and the data display module is configured to display the data name and the data content corresponding to the data name in the debugging page.
9. An electronic device, comprising:
a processor;
a memory for storing the processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the data processing method of any one of claims 1 to 7.
10. A storage medium, wherein instructions in the storage medium, when executed by a processor of an electronic device, enable the electronic device to perform the data processing method of any one of claims 1 to 7.
CN202010814514.6A 2020-08-13 2020-08-13 Data processing method and device, electronic equipment and storage medium Pending CN112069060A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010814514.6A CN112069060A (en) 2020-08-13 2020-08-13 Data processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010814514.6A CN112069060A (en) 2020-08-13 2020-08-13 Data processing method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112069060A true CN112069060A (en) 2020-12-11

Family

ID=73661352

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010814514.6A Pending CN112069060A (en) 2020-08-13 2020-08-13 Data processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112069060A (en)

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104796929A (en) * 2014-01-22 2015-07-22 腾讯科技(深圳)有限公司 Network debugging method and device
CN105955888A (en) * 2016-05-04 2016-09-21 腾讯科技(深圳)有限公司 Page debugging and previewing method and system
CN108491247A (en) * 2018-04-10 2018-09-04 武汉斗鱼网络科技有限公司 Method for page jump, device, terminal and computer-readable medium
CN109558323A (en) * 2018-11-30 2019-04-02 百度在线网络技术(北京)有限公司 For debugging system, the method and apparatus of the page
CN109582580A (en) * 2018-11-30 2019-04-05 百度在线网络技术(北京)有限公司 For debugging system, the method and apparatus of the page
CN109740074A (en) * 2018-11-30 2019-05-10 浙江口碑网络技术有限公司 Processing method, device and the equipment of parameter configuration
CN110489333A (en) * 2019-07-22 2019-11-22 北京字节跳动网络技术有限公司 A kind of method, apparatus based on detector tune-up data, medium and electronic equipment
CN110808868A (en) * 2019-09-12 2020-02-18 中国平安财产保险股份有限公司 Test data acquisition method and device, computer equipment and storage medium
CN111274420A (en) * 2020-02-07 2020-06-12 京东数字科技控股有限公司 Data processing method and device, electronic equipment and storage medium
CN111367805A (en) * 2020-03-05 2020-07-03 中国银行股份有限公司 Development and debugging method and device

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104796929A (en) * 2014-01-22 2015-07-22 腾讯科技(深圳)有限公司 Network debugging method and device
CN105955888A (en) * 2016-05-04 2016-09-21 腾讯科技(深圳)有限公司 Page debugging and previewing method and system
CN108491247A (en) * 2018-04-10 2018-09-04 武汉斗鱼网络科技有限公司 Method for page jump, device, terminal and computer-readable medium
CN109558323A (en) * 2018-11-30 2019-04-02 百度在线网络技术(北京)有限公司 For debugging system, the method and apparatus of the page
CN109582580A (en) * 2018-11-30 2019-04-05 百度在线网络技术(北京)有限公司 For debugging system, the method and apparatus of the page
CN109740074A (en) * 2018-11-30 2019-05-10 浙江口碑网络技术有限公司 Processing method, device and the equipment of parameter configuration
CN110489333A (en) * 2019-07-22 2019-11-22 北京字节跳动网络技术有限公司 A kind of method, apparatus based on detector tune-up data, medium and electronic equipment
CN110808868A (en) * 2019-09-12 2020-02-18 中国平安财产保险股份有限公司 Test data acquisition method and device, computer equipment and storage medium
CN111274420A (en) * 2020-02-07 2020-06-12 京东数字科技控股有限公司 Data processing method and device, electronic equipment and storage medium
CN111367805A (en) * 2020-03-05 2020-07-03 中国银行股份有限公司 Development and debugging method and device

Similar Documents

Publication Publication Date Title
CN107329743B (en) Application page display method and device and storage medium
CN111273899B (en) Code processing method, device, electronic equipment and storage medium
CN106547547B (en) data acquisition method and device
CN114240882A (en) Defect detection method and device, electronic equipment and storage medium
US10831514B2 (en) Display method and device of application interface
CN107463372B (en) Data-driven page updating method and device
CN110413169B (en) Information display method, device and medium
CN106503048B (en) Browser color setting method and device
CN112416751A (en) Processing method and device for interface automation test and storage medium
CN112685269A (en) Data acquisition method and device, electronic equipment and storage medium
CN110543265A (en) Page title bar generation method and device, electronic equipment and storage medium
CN112069060A (en) Data processing method and device, electronic equipment and storage medium
CN111061633B (en) Webpage first screen time detection method, device, terminal and medium
CN110147817B (en) Training data set generation method and device
CN111240927A (en) Method, device and storage medium for detecting time consumption of method in program
CN112333233A (en) Event information reporting method and device, electronic equipment and storage medium
CN111596980A (en) Information processing method and device
CN112000571A (en) Test method, test device and test device
CN107423060B (en) Animation effect presenting method and device and terminal
CN113407879A (en) Data reporting method, device and readable medium
CN113360051A (en) Search prompting method and device, mobile terminal and storage medium
CN111611470A (en) Data processing method and device and electronic equipment
CN111382061A (en) Test method, test device, test medium and electronic equipment
US9679076B2 (en) Method and device for controlling page rollback
CN114554283B (en) Target object display method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination