CN114924956A - Code review method, device, equipment and medium - Google Patents

Code review method, device, equipment and medium Download PDF

Info

Publication number
CN114924956A
CN114924956A CN202210524645.XA CN202210524645A CN114924956A CN 114924956 A CN114924956 A CN 114924956A CN 202210524645 A CN202210524645 A CN 202210524645A CN 114924956 A CN114924956 A CN 114924956A
Authority
CN
China
Prior art keywords
review
code
target
message card
button
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
CN202210524645.XA
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 Baidu Netcom Science and Technology Co Ltd
Original Assignee
Beijing Baidu Netcom Science and 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 Baidu Netcom Science and Technology Co Ltd filed Critical Beijing Baidu Netcom Science and Technology Co Ltd
Priority to CN202210524645.XA priority Critical patent/CN114924956A/en
Publication of CN114924956A publication Critical patent/CN114924956A/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/3604Software analysis for verifying properties of programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • G06Q10/103Workflow collaboration or project management

Landscapes

  • Engineering & Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Theoretical Computer Science (AREA)
  • Strategic Management (AREA)
  • Human Resources & Organizations (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Quality & Reliability (AREA)
  • Computer Hardware Design (AREA)
  • Software Systems (AREA)
  • Data Mining & Analysis (AREA)
  • General Engineering & Computer Science (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Operations Research (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The disclosure provides a code review method, a device, equipment, a medium and a program product, relates to the technical field of computers, and particularly relates to a code review technology. The specific implementation scheme is as follows: responding to the trigger operation of a submitter of a target code on an initiating review button on preset communication software, and acquiring a target reviewer selected by the submitter, wherein a candidate list of the initiating review button and the reviewer is displayed on an initiating review message card, and the initiating review message card is displayed on the communication software; assembling a request review message card, and sending the request review message card to the target reviewer through the communication software, wherein a review button aiming at the target code is displayed on the request review message card; and responding to the triggering operation of the target reviewer on the review button, and displaying a code review page of the target code on a code platform. The code review efficiency can be improved, and the labor cost is saved.

Description

Code review method, device, equipment and medium
Technical Field
The present disclosure relates to the field of computer technologies, and in particular, to a code review technology, and in particular, to a code review method, apparatus, device, medium, and program product.
Background
Currently, the IT industry is the most popular industry at home and abroad, and IT seems that every corner of life is full of development and design of engineers, but the basis for realizing all the things comes from every line of codes in the hands of engineers.
The most key work content of a software development line is from writing codes, submitting codes to reviewing codes and merging codes, wherein code review is an extremely important link and is a first gate for ensuring the quality of the codes. Therefore, it is imperative to improve the efficiency of code review.
Disclosure of Invention
The present disclosure provides a code review method, apparatus, device, medium, and program product.
According to an aspect of the present disclosure, there is provided a code review method including:
responding to the trigger operation of a submitter of a target code on an initiation review button on preset communication software, and acquiring a target reviewer selected by the submitter, wherein the initiation review button and a candidate list of the reviewer are displayed on an initiation review message card, and the initiation review message card is displayed on the communication software;
assembling a request review message card, and sending the request review message card to the target reviewer through the communication software, wherein a review button aiming at the target code is displayed on the request review message card;
and responding to the triggering operation of the target reviewer on the review button, and displaying a code review page of the target code on a code platform.
According to another aspect of the present disclosure, there is provided a code review device including:
the target reviewer acquisition module is used for responding to the trigger operation of a submitter of a target code on an initiation review button on preset communication software and acquiring a target reviewer selected by the submitter, wherein the initiation review button and a candidate list of the reviewer are displayed on an initiation review message card, and the initiation review message card is displayed on the communication software;
the request review message card assembly module is used for assembling a request review message card and sending the request review message card to the target reviewer through the communication software, wherein a review button aiming at the target code is displayed on the request review message card;
and the code review page display module is used for responding to the triggering operation of the target reviewer on the review button and displaying a code review page of the target code on a code platform.
According to another aspect of the present disclosure, there is provided an electronic device including:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein, the first and the second end of the pipe are connected with each other,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the code review method of any embodiment of the disclosure.
According to another aspect of the present disclosure, there is provided a non-transitory computer-readable storage medium storing computer instructions for causing a computer to perform the code review method according to any of the embodiments of the present disclosure.
According to another aspect of the present disclosure, there is provided a computer program product comprising a computer program which, when executed by a processor, implements the code review method of any of the embodiments of the present disclosure.
It should be understood that the statements in this section are not intended to identify key or critical features of the embodiments of the present disclosure, nor are they intended to limit the scope of the present disclosure. Other features of the present disclosure will become apparent from the following description.
Drawings
The drawings are included to provide a better understanding of the present solution and are not to be construed as limiting the present disclosure. Wherein:
FIG. 1 is a schematic flow diagram of a code review method according to an embodiment of the present disclosure;
FIG. 2 is a schematic flow diagram of a code review method according to an embodiment of the present disclosure;
FIG. 3a is a schematic flow chart diagram of a method of code review according to an embodiment of the present disclosure;
FIG. 3b is a schematic diagram of an initiate review message card in accordance with an embodiment of the present disclosure;
FIG. 3c is a schematic diagram of a request to review a message card in accordance with an embodiment of the present disclosure;
FIG. 3d is a schematic illustration of a review page in accordance with an embodiment of the present disclosure;
FIG. 3e is a schematic diagram of a review result message card in accordance with an embodiment of the present disclosure;
FIG. 4 is a schematic diagram of a code review device according to an embodiment of the present disclosure;
FIG. 5 is a block diagram of an electronic device for implementing the code review method of an embodiment of the present disclosure.
Detailed Description
Exemplary embodiments of the present disclosure are described below with reference to the accompanying drawings, in which various details of the embodiments of the disclosure are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the disclosure. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
Fig. 1 is a schematic flowchart of a code review method according to an embodiment of the present disclosure, which is applicable to a situation of reviewing a software code, and relates to the field of computer technologies, in particular to a code review technology. The method can be executed by a code review device, which is implemented in software and/or hardware, and is preferably configured in an electronic device, such as a mobile terminal or a computer device. As shown in fig. 1, the method specifically includes the following steps:
s101, responding to the trigger operation of the submitter of the target code on the initiation review button on preset communication software, and acquiring the target reviewer selected by the submitter, wherein the initiation review button and a candidate list of the reviewer are displayed on an initiation review message card, and the initiation review message card is displayed on the communication software.
The communication software may be any software installed on the electronic device and capable of realizing instant messaging. The message card for initiating review is a message card which is assembled by the message notification platform based on the message card technology and can be displayed on the communication software. The message notification platform may be an independent service running on the electronic device, and may also exist as a sub-service in the communication software, which is not limited in this embodiment of the present disclosure. The message card initiating review can be displayed in a pop-up window form or a message window form on the communication software, and the display form of the message card initiating review on the communication software is not limited in any way in the embodiment of the disclosure.
An initiate review button and a candidate list of reviewers are displayed on the initiate review message card. When the initiated review message card is displayed on the communication software, the submitter can select a target reviewer of the target code from the candidate list of the reviewer and trigger the initiated review button to initiate a review request for the target code to the target reviewer.
And S102, assembling a request review message card, and sending the request review message card to a target reviewer through the communication software, wherein a review button aiming at a target code is displayed on the request review message card.
When the submitter triggers the initiation review button on the initiation review message card, the message notification platform receives the initiation review request, assembles the request review message card based on the request, and sends the request review message card to the target reviewer through the communication software, and the request review message card is displayed with the review button aiming at the target code.
S103, responding to the trigger operation of the target reviewer on the review button, and displaying a code review page of the target code on the code platform.
The target reviewer receives the request review message card on the communication software, knows that a review task aiming at the target code exists at present, and then triggers a review button on the request review message card. And the notification message platform responds to the trigger, and immediately displays a code review page aiming at the target code on the code platform on the electronic equipment for the target reviewer to review the code.
It should be noted that, in the prior art, generally, after a programmer a writes a code, the code is submitted to a code platform, then, the programmer a finds a reviewer B and notifies that there is a code review task, and the reviewer B finds a review page of a target code after logging in the code platform and starts review. In the embodiment of the disclosure, the code review is realized based on a message card mechanism, so that no additional communication cost is needed between the submitter and the target reviewer, the message notification platform is responsible for assembling the message card needed in the code review and directly displaying the message card in the communication software, and the communication software is a communication tool frequently used by people in daily work, so that no additional communication cost is caused. When the submitter and the target reviewer see the corresponding message cards on the communication software, on one hand, the submitter and the target reviewer can visually know the current task and the links of the code review, and on the other hand, the code review process can be promoted by triggering the function buttons displayed on the message cards. In a word, for the submitter and the target reviewer, code review can be completed only by performing simple operation on communication software based on the message card, and the code review efficiency is improved.
According to the technical scheme of the embodiment, based on a message card mechanism, the notification message and the trigger operation of each node in the code review process are displayed on the message card and sent to the submitter or the reviewer through the communication software, so that the submitter and the reviewer can directly check the detailed content on the message card displayed by the communication software and trigger the relevant operation of code review, the code review can be automatically completed anytime and anywhere, and the code review efficiency is improved.
Fig. 2 is a schematic flowchart of a code review method according to an embodiment of the present disclosure, and the embodiment further performs optimization based on the above embodiment. As shown in fig. 2, the method specifically includes the following steps:
s201, obtaining information of the target code and a machine inspection result from the code platform, wherein the information of the target code comprises a code library address of the target code, submitter information and a candidate list of reviewers.
The submitter submits the target code to a code platform, and the code platform firstly carries out machine inspection on the target code, wherein the machine inspection comprises coding specification scanning, defect scanning, safety scanning, unit testing, streamline automation tasks and the like. After the machine inspection, the code platform sends the information of the target code and the corresponding machine inspection result to the message notification platform.
S202, assembling the initiated review message card according to the information of the target code and the machine check result, and sending the initiated review message card to the submitter through the communication software.
And after the message notification platform acquires the information of the target code and the machine inspection result, assembling and initiating a review message card. The card for initiating review message can display a button for initiating review, a candidate list of reviewers, abstract information of machine check results and a button for checking details of the machine check results. In addition, if the target code has a default reviewer, the information of the default reviewer can be directly displayed on the review initiation message card.
And S203, responding to the trigger operation of the submitting person on the machine inspection result detail viewing button, and displaying the detailed content of the machine inspection result.
When the object code does not pass the machine check, the related matters can be recorded in the detailed content of the machine check result so as to be convenient for the submitter to modify.
And S204, responding to the trigger operation of the submitter of the target code on the initiation review button on the communication software, and acquiring the target reviewer selected by the submitter.
And S205, assembling the request review message card, and sending the request review message card to the target reviewer through the communication software.
And in addition, a code library address and submitter information of the target code can be displayed so as to be conveniently viewed by the target reviewer.
And S206, responding to the trigger operation of the target reviewer on the review button, and displaying a code review page of the target code on the code platform.
Specifically, a code review page of the target code on the code platform can be displayed through a pre-installed code review plug-in, wherein the code review plug-in and the communication software are installed on the mobile terminal, so that even if a submitter and a reviewer are not beside a computer, the review can be finished through the mobile terminal, and the code review efficiency is improved.
And S207, responding to the triggering operation of the target reviewer on the review result publishing button displayed on the code review page, and acquiring the review result of the target code.
And the target reviewer revises the code review page according to the conventional review operation, in addition, a review result publishing button is displayed on the code review page, and when the review is finished, the target reviewer can trigger the review result publishing button. And the message notification platform responds to the triggering operation of the target reviewer on the review result publishing button and acquires the review result of the target code.
And S208, assembling a review result message card according to the review result, and sending the review result message card to the submitter through the communication software.
And the message notification platform assembles a review result message card according to the review result and sends the review result message card to the submitter through the communication software so as to notify the submitter of the review result of the target code.
S209, responding to the trigger operation of the submitter on the code joining button displayed on the review result message card, and sending a joining request of the target code to the code platform.
And the review result message card can display summary information and code incorporating buttons of the review result. If the target code passes the review, the submitter can trigger a code import button, the message informs the platform to respond to the trigger, sends an import request of the target code to the code platform, and the code platform imports the target code into the code library, so that the whole code review process is completed.
In addition, a review result detail viewing button can be displayed on the review result message card, if the target code is not reviewed, the submitter can trigger the button, the message notification platform responds to the trigger operation, and the detailed content of the review result is displayed for the submitter to view so that the submitter can modify the target code. And when the submitter modifies the target code again, uploading the modified target code to the code platform again, and reviewing again according to the method disclosed by the embodiment of the disclosure.
According to the technical scheme of the embodiment, after the submitter submits the target code to the code platform, the code platform performs machine evaluation, and then based on a message card mechanism, the notification message and the trigger operation of each node in the code evaluation process are displayed on the message card and sent to the submitter or the reviewer through the communication software, so that the submitter and the reviewer can directly view detailed contents on the message card displayed by the communication software and trigger the relevant operation of code evaluation, the code evaluation can be realized at any time and any place and in full automation, and the code evaluation efficiency is improved.
Fig. 3a is a schematic flowchart of a code review method according to an embodiment of the present disclosure, and the embodiment further performs optimization based on the above embodiment. As shown in fig. 3a, steps 1 to 9 involved in the method are specifically:
step 1, a code submitter submits target codes to a code warehouse (the unexamined codes are stored in a temporary storage area of the code warehouse);
step 2, the code platform carries out machine inspection on the target code;
step 3, the code platform sends the machine inspection result and the information of the target code to a message notification platform;
step 4, the message notification platform sends the assembled message card for initiating review to a code submitter through communication software;
step 5, the code submitter selects the code reviewer through the initiated review message card and triggers an initiated review button displayed on the initiated review message card;
step 6, the message notification platform sends the assembled message card for requesting review to the code reviewer;
step 7, the code reviewer triggers a review button displayed on the request review message card, reviews the message card on a review page, and then triggers a review result publishing button displayed on the review page;
step 8, the message notification platform sends the assembled review result message card to a code submitter;
and 9, triggering an incorporation button displayed on the review result message card by the code submitter, and incorporating the target code into the code warehouse by the code platform.
Illustratively, fig. 3b, fig. 3c, fig. 3d, and fig. 3e are schematic diagrams of an initiating review message card, a requesting review message card, a review page, and a review result message card, respectively, according to an embodiment of the present disclosure. It should be noted that the contents shown in fig. 3b, fig. 3c, fig. 3d, and fig. 3e are all examples, and the embodiment of the present disclosure does not limit the contents and the layout thereof displayed on various types of message cards and review pages.
In the message card for initiating review shown in fig. 3b, the area 31 displays the name of the target code, the area 32 displays the result of the machine check, the area 33 displays the default reviewer, the area 34 displays the address book, the submitter can select the specified target reviewer in this area, and the area 35 is the initiating button, and if the submitter triggers the button, the reviewer can view the message card for requesting review shown in fig. 3c on the communication software.
In the request review message card shown in fig. 3c, a word "you have a new code to review" is displayed to prompt the reviewer to have a new review task, a region 36 shows the name of the code to be reviewed, a region 37 shows the submitter, a region 38 shows the address of the code to be reviewed in the code library, and a region 39 is a view details button, which is triggered by the reviewer to enter the review page shown in fig. 3d for review.
In the review page shown in fig. 3d, the area 40 is a scoring area, the area 41 is a review area, and the reviewer can score and write reviews in the two areas, and after the review is completed, the posting button displayed in the area 42 is triggered, and the submitter can see the review result message card shown in fig. 3e on the communication software.
In the review result message card shown in fig. 3e, "code review result: the word of + 2' is used for prompting the total review score of the current code of the submitter, the area 43 displays the address of the code library, the area 44 displays the review subject, the area 45 displays the number of the reviews, the area 46 is a button for viewing details, and the area 47 is a button for joining. And if the submitter triggers the detail checking button, the submitter can check the detail information of the code review, and if the enrollment button is triggered, the code platform enrolls the code into the code library.
According to the technical scheme of the embodiment, based on a message card mechanism, the notification message and the trigger operation of each node in the code review process are displayed on the message card and sent to the submitter or the reviewer through the communication software, so that the submitter and the reviewer can directly check the detailed content on the message card displayed by the communication software and trigger the relevant operation of code review, the code review can be automatically completed anytime and anywhere, and the code review efficiency is improved. Specifically, the following effects can be achieved:
(1) the submitter submits the code, and after all machine inspections are finished, the submitter is automatically prompted in a message card mode without manually refreshing a page by the submitter to check a machine inspection result;
(2) the submitter clicks the message card in the step (1), selects a code reviewer (a selectable person or group chat) and sends the review card to the reviewer without manually copying a review link to send to the reviewer; the reviewer receives the message card and is clear at a glance without communication cost, and jumps to a review page for review by clicking a review button displayed on the card;
(3) when the reviewer is not beside the PC, the code can be reviewed on the mobile terminal through a pre-installed review plug-in, so that the method is convenient and quick;
(4) after the reviewer revives the codes, the message notification platform immediately sends a review result message card to the submitter in a human-human conversation mode, the message card is provided with an 'enter' button, the submitter clicks the 'enter' button to enter the codes after receiving the message card, and the submitter is immediately reminded to enter the codes after the code review is finished;
(5) using the method of the disclosed embodiment, 3000+ samples per day, from code submission to code incorporation, can be reduced by an average of 13.6 hours each time.
Fig. 4 is a schematic structural diagram of a code review device according to an embodiment of the present disclosure, and this embodiment is applicable to a case of reviewing a software code, and relates to the field of computer technologies, in particular to a code review technology. The device can realize the code review method in any embodiment of the disclosure. As shown in fig. 4, the apparatus 400 specifically includes:
a target reviewer acquiring module 401, configured to acquire a target reviewer selected by a submitter in response to a trigger operation of the submitter of a target code on a preset communication software on an initiating review button, where the initiating review button and a candidate list of the reviewer are displayed on an initiating review message card, and the initiating review message card is displayed on the communication software;
a request review message card assembling module 402, configured to assemble a request review message card, and send the request review message card to the target reviewer through the communication software, where a review button for the target code is displayed on the request review message card;
and a code review page display module 403, configured to display a code review page of the target code on the code platform in response to the trigger operation of the target reviewer on the review button.
Optionally, the apparatus further includes an assembly module of a review initiating message card, configured to implement the following operations before the target reviewer obtaining module 401 responds to the trigger operation of the submitter of the target code on the review initiating button on the preset communication software, and obtains the target reviewer selected by the submitter:
acquiring information of the target code and a machine inspection result from the code platform, wherein the information of the target code comprises a code library address of the target code, the information of the submitter and a candidate list of the reviewer;
and assembling the message card for initiating review according to the information of the target code and the machine inspection result, and sending the message card for initiating review to the submitter through the communication software.
Optionally, the card for initiating review message further displays summary information of the machine review result and a button for viewing details of the machine review result; correspondingly, the device further comprises:
and the machine inspection result display module is used for responding to the trigger operation of the submitter on the machine inspection result detail viewing button and displaying the detailed content of the machine inspection result.
Optionally, the request review message card further displays a code library address of the target code and the information of the submitter.
Optionally, the code review page display module 403 is specifically configured to:
and displaying a code review page of the target code on a code platform through a pre-installed code review plug-in, wherein the code review plug-in and the communication software are installed on a mobile terminal.
Optionally, a review result publishing button is displayed on the code review page; correspondingly, the device also comprises a review result message card assembly module, which is specifically used for:
responding to the triggering operation of the target reviewer on the review result publishing button, and acquiring the review result of the target code;
and assembling a review result message card according to the review result, and sending the review result message card to the submitter through the communication software.
Optionally, a code entry button is displayed on the review result message card; correspondingly, the device further comprises:
and the joining request sending module is used for responding to the trigger operation of the submitter on the code joining button and sending the joining request of the target code to the code platform.
Optionally, a review result message card is provided with a review button for displaying summary information and review result details of the review result; correspondingly, the device further comprises:
and the review result display module is used for responding to the trigger operation of the submitter on the review result detail viewing button and displaying the detailed content of the review result.
The product can execute the method provided by any embodiment of the disclosure, and has corresponding functional modules and beneficial effects of the execution method.
In the technical scheme of the disclosure, the processes of collecting, storing, using, processing, transmitting, providing, disclosing and the like of the personal information of the related user all accord with the regulations of related laws and regulations, and do not violate the common customs of public order.
The present disclosure also provides an electronic device, a readable storage medium, and a computer program product according to embodiments of the present disclosure.
FIG. 5 illustrates a schematic block diagram of an example electronic device 500 that can be used to implement embodiments of the present disclosure. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 5, the apparatus 500 comprises a computing unit 501 which may perform various appropriate actions and processes in accordance with a computer program stored in a Read Only Memory (ROM)502 or a computer program loaded from a storage unit 508 into a Random Access Memory (RAM) 503. In the RAM503, various programs and data required for the operation of the device 500 can also be stored. The computing unit 501, the ROM 502, and the RAM503 are connected to each other via a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
A number of components in the device 500 are connected to the I/O interface 505, including: an input unit 506 such as a keyboard, a mouse, or the like; an output unit 507 such as various types of displays, speakers, and the like; a storage unit 508, such as a magnetic disk, optical disk, or the like; and a communication unit 509 such as a network card, modem, wireless communication transceiver, etc. The communication unit 509 allows the device 500 to exchange information/data with other devices through a computer network such as the internet and/or various telecommunication networks.
The computing unit 501 may be a variety of general-purpose and/or special-purpose processing components having processing and computing capabilities. Some examples of the computing unit 501 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The computing unit 501 performs the various methods and processes described above, such as a code review method. For example, in some embodiments, the code review method may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 508. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device 500 via the ROM 502 and/or the communication unit 509. When the computer program is loaded into RAM503 and executed by computing unit 501, one or more steps of the code review methods described above may be performed. Alternatively, in other embodiments, the computing unit 501 may be configured to perform the code review method in any other suitable manner (e.g., by way of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuitry, Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), system on a chip (SOCs), Complex Programmable Logic Devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs that are executable and/or interpretable on a programmable system including at least one programmable processor, which may be special or general purpose, receiving data and instructions from, and transmitting data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for implementing the methods of the present disclosure may be written in any combination of one or more programming languages. These program code may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program code, when executed by the processor or controller, causes the functions/acts specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), blockchain networks, and the internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. The server can be a cloud server, also called a cloud computing server or a cloud host, and is a host product in a cloud computing service system, so that the defects of high management difficulty and weak service expansibility in the traditional physical host and VPS service are overcome. The server may also be a server of a distributed system, or a server incorporating a blockchain.
Artificial intelligence is the subject of research that makes computers simulate some human mental processes and intelligent behaviors (such as learning, reasoning, thinking, planning, etc.), both at the hardware level and at the software level. Artificial intelligence hardware technologies generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing, and the like; the artificial intelligence software technology mainly comprises a computer vision technology, a voice recognition technology, a natural language processing technology, a machine learning/deep learning technology, a big data processing technology, a knowledge map technology and the like.
Cloud computing (cloud computing) refers to accessing an elastically extensible shared physical or virtual resource pool through a network, where resources may include servers, operating systems, networks, software, applications, storage devices, and the like, and may be a technical system that deploys and manages resources in a self-service manner as needed. Through the cloud computing technology, high-efficiency and strong data processing capacity can be provided for technical application and model training of artificial intelligence, block chains and the like.
It should be understood that various forms of the flows shown above may be used, with steps reordered, added, or deleted. For example, the steps described in this disclosure may be performed in parallel or sequentially or in a different order, as long as the desired results of the technical solutions provided by this disclosure can be achieved, and are not limited herein.
The above detailed description should not be construed as limiting the scope of the disclosure. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may be made, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present disclosure should be included in the protection scope of the present disclosure.

Claims (12)

1. A code review method comprising:
responding to the trigger operation of a submitter of a target code on an initiating review button on preset communication software, and acquiring a target reviewer selected by the submitter, wherein the initiating review button and a candidate list of the reviewer are displayed on an initiating review message card, and the initiating review message card is displayed on the communication software;
assembling a request review message card, and sending the request review message card to the target reviewer through the communication software, wherein a review button aiming at the target code is displayed on the request review message card;
and responding to the triggering operation of the target reviewer on the review button, and displaying a code review page of the target code on a code platform.
2. The method of claim 1, before the target reviewer selected by the submitter is obtained in response to the trigger operation of the submitter of the target code on the initiation review button on the preset communication software, the method further comprising:
acquiring information of the target code and a machine inspection result from the code platform, wherein the information of the target code comprises a code library address of the target code, the information of the submitter and a candidate list of the reviewer;
and assembling the initiated review message card according to the information of the target code and the machine check result, and sending the initiated review message card to the submitter through the communication software.
3. The method of claim 2, wherein said initiate review message card further displays thereon summary information of said machine check result and a machine check result detail view button; correspondingly, the method further comprises the following steps:
and displaying the detailed content of the machine inspection result in response to the trigger operation of the submitter on the machine inspection result detail viewing button.
4. The method of claim 2, wherein the request review message card further displays a code library address of the object code and the submitter information thereon.
5. The method of claim 1, wherein said displaying the target code on a code review page of a code platform comprises:
and displaying a code review page of the target code on a code platform through a pre-installed code review plug-in, wherein the code review plug-in and the communication software are installed on a mobile terminal.
6. The method of claim 1, wherein a review result posting button is displayed on the code review page; correspondingly, the method further comprises the following steps:
responding to the triggering operation of the target reviewer on the review result publishing button, and acquiring the review result of the target code;
and assembling a review result message card according to the review result, and sending the review result message card to the submitter through the communication software.
7. The method of claim 6, wherein a code-in button is displayed on the review result message card; correspondingly, the method further comprises the following steps:
and responding to the trigger operation of the submitter on the code incorporation button, and sending the incorporation request of the target code to the code platform.
8. The method of claim 6, wherein the review result message card has displayed thereon summary information of the review result and a review result detail view button; correspondingly, the method further comprises the following steps:
and responding to the trigger operation of the submitter on the detail viewing button of the review result, and displaying the detailed content of the review result.
9. A code review device comprising:
the target reviewer acquisition module is used for responding to the trigger operation of a submitter of a target code on an initiation review button on preset communication software and acquiring a target reviewer selected by the submitter, wherein the initiation review button and a candidate list of the reviewer are displayed on an initiation review message card, and the initiation review message card is displayed on the communication software;
the request review message card assembly module is used for assembling a request review message card and sending the request review message card to the target reviewer through the communication software, wherein a review button aiming at the target code is displayed on the request review message card;
and the code review page display module is used for responding to the triggering operation of the target reviewer on the review button and displaying a code review page of the target code on a code platform.
10. An electronic device, comprising:
at least one processor; and
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the code review method of any one of claims 1-8.
11. A non-transitory computer-readable storage medium having stored thereon computer instructions for causing a computer to perform the code review method of any one of claims 1-8.
12. A computer program product comprising a computer program which, when executed by a processor, implements a code review method according to any of claims 1-8.
CN202210524645.XA 2022-05-13 2022-05-13 Code review method, device, equipment and medium Pending CN114924956A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210524645.XA CN114924956A (en) 2022-05-13 2022-05-13 Code review method, device, equipment and medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210524645.XA CN114924956A (en) 2022-05-13 2022-05-13 Code review method, device, equipment and medium

Publications (1)

Publication Number Publication Date
CN114924956A true CN114924956A (en) 2022-08-19

Family

ID=82808530

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210524645.XA Pending CN114924956A (en) 2022-05-13 2022-05-13 Code review method, device, equipment and medium

Country Status (1)

Country Link
CN (1) CN114924956A (en)

Similar Documents

Publication Publication Date Title
CN113590776A (en) Text processing method and device based on knowledge graph, electronic equipment and medium
CN113221565A (en) Entity recognition model training method and device, electronic equipment and storage medium
CN111767334A (en) Information extraction method and device, electronic equipment and storage medium
CN114445047A (en) Workflow generation method and device, electronic equipment and storage medium
CN114428902A (en) Information searching method and device, electronic equipment and storage medium
CN113626441A (en) Text management method, device and equipment based on scanning equipment and storage medium
CN113609100A (en) Data storage method, data query method, data storage device, data query device and electronic equipment
CN113342954A (en) Image information processing method and device applied to question-answering system and electronic equipment
CN116257690A (en) Resource recommendation method and device, electronic equipment and storage medium
CN113554062B (en) Training method, device and storage medium for multi-classification model
CN115618234A (en) Model training method, device, equipment and storage medium
CN114924956A (en) Code review method, device, equipment and medium
CN113360672B (en) Method, apparatus, device, medium and product for generating knowledge graph
CN114547252A (en) Text recognition method and device, electronic equipment and medium
CN114118937A (en) Information recommendation method and device based on task, electronic equipment and storage medium
CN113705206B (en) Emotion prediction model training method, device, equipment and storage medium
CN114281981B (en) News brief report generation method and device and electronic equipment
CN113343090B (en) Method, apparatus, device, medium and product for pushing information
CN113408274B (en) Method for training language model and label setting method
CN117573561B (en) Automatic test system, method, electronic equipment and storage medium
CN109656961B (en) Method and device for searching homonymous tasks based on data analysis, medium and electronic equipment
CN113407745A (en) Data annotation method and device, electronic equipment and computer readable storage medium
CN115357793A (en) Information recommendation method and device, electronic equipment and storage medium
CN114329205A (en) Method and device for pushing information
CN114401337A (en) Data sharing method, device and equipment based on cloud mobile phone 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